﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web.Security;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.IO;
using Maticsoft.Common;
using DQYT.HTDZ.DBUtility;
using DQYT.HTDZ.BusinessService;
using System.Xml;
using System.Text;
using System.Drawing;
using DQYT.HTDZ.Common;
using DQYT.HTDZ.BLL;
using DQYT.HTDZ.Model;
namespace DQYT.HTDZ.Web.Views.Analysis.balance
{
    public partial class Balance : System.Web.UI.Page
    {
        private BDDATESOURCEModel bddatesoursemodel;
        private BDPULLModel bdpullmodel;
        private BDPOVERMACHINEModel djmodel;
        private BDVALUEModel valuemodel;

        private BDDATESOURSEBLL datesoursedll;
        private BDPULLBLL pullbll;
        private BDPOVERMACHINEBLL djbll;
        private BDVALUEBLL valuebll;
        protected void Page_Load(object sender, EventArgs e)
        {
            BDValueFunc fun = new BDValueFunc();
            //根据井号和检测日期获得基础数据表
            bddatesoursemodel = fun.getdatesousemodel("5T10-38", "2013/4/25 12:14:59");
            //获得特征值
            //BDValueFunc bdvaluefun = new BDValueFunc();
            //valuemodel = bdvaluefun.getValue(bddatesoursemodel);
            valuemodel = fun.getValueModel("5T10-38", "2013/4/25 12:14:59");
            //根据抽油机ID获得抽油机相关信息 
            //根据电机ID获得电机相关信息
            if (!IsPostBack)
            {
                init();
            }
        }
        /// <summary>
        /// 初始化界面
        /// </summary>
        protected void init()
        {
            this.txt_WELLID.Text = valuemodel.WELLID.ToString();
            this.txt_JCRQ.Text = valuemodel.JCRQ.ToString();

            this.txt_SXYGMAX.Text = valuemodel.SXYGMAX.ToString();
            this.txt_XXYGMAX.Text = valuemodel.XXYGMAX.ToString();
            this.txt_YGZDZPHD.Text = valuemodel.YGZDZPHD.ToString();
            this.txt_SXNJJFG.Text = valuemodel.SXNJJFG.ToString();
            this.txt_XXNJJFG.Text = valuemodel.XXNJJFG.ToString();
            this.txt_NJJFGPHD.Text = valuemodel.NJJFGPHD.ToString();
            this.txt_YGFZL.Text = valuemodel.YGFZL.ToString();
            this.txt_YGPZL.Text = valuemodel.YGPZL.ToString();
            this.txt_NJPZL.Text = valuemodel.NJPZL.ToString();
            this.txt_NJFZL.Text = valuemodel.NJFZL.ToString();

        }

    }
}